package com.wangshidai.entity;

import com.wangshidai.util.userztreeutil.Treeable;
import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;

import java.util.List;

/**
 *
 */
@Data
@AllArgsConstructor
@NoArgsConstructor
public class TreeNode implements Treeable {
    private Integer id;
    private Integer pid;
    private String likeId  ;//   varchar2(30)  y
    private String deptAddress  ;//   varchar2(30)  y
    private String deptCode  ;//   varchar2(30)  y
    private String deptPhone  ;//   varchar2(30)  y
    private String manager;// varchar2(32)  y
    private String name   ;//  varchar2(50)  y
    private String open   ;//  varchar2(50)  y
    private Integer orderNum   ;//  varchar2(50)  y
    private String parentName   ;//  varchar2(50)  y
    private List<TreeNode> children;

//    @Override
//    public Integer getMapKey() {
//        return pid;
//    }
//
//    @Override
//    public Integer getChildrenKey() {
//        return id;
//    }
//
//    @Override
//    public Integer getRootKey() {
//        return 0;
//    }

    @Override
    public void setChildren(List children) {
        this.children = children;
    }
}
